package org.dromara.admin.domain.vo;

import java.math.BigDecimal;
import org.dromara.admin.domain.OrderProduct;
import cn.idev.excel.annotation.ExcelIgnoreUnannotated;
import cn.idev.excel.annotation.ExcelProperty;
import org.dromara.common.excel.annotation.ExcelDictFormat;
import org.dromara.common.excel.convert.ExcelDictConvert;
import io.github.linpeilie.annotations.AutoMapper;
import lombok.Data;

import java.io.Serial;
import java.io.Serializable;
import java.util.Date;



/**
 * 订单产品明细关联视图对象 bi_order_product
 *
 * @author Lion Li
 * @date 2025-10-10
 */
@Data
@ExcelIgnoreUnannotated
@AutoMapper(target = OrderProduct.class)
public class OrderProductVo implements Serializable {

    @Serial
    private static final long serialVersionUID = 1L;

    /**
     * 关联唯一ID
     */
    @ExcelProperty(value = "关联唯一ID")
    private Long id;

    /**
     * 关联订单ID（关联bi_order.id）
     */
    @ExcelProperty(value = "关联订单ID", converter = ExcelDictConvert.class)
    private Long orderId;

    /**
     * 关联产品ID（关联bi_product.id）
     */
    @ExcelProperty(value = "关联产品ID", converter = ExcelDictConvert.class)
    private Long productId;

    /**
     * 产品数量
     */
    @ExcelProperty(value = "产品数量")
    private Integer quantity;

    /**
     * 订单中产品实际单价（支持“一客一价”）
     */
    @ExcelProperty(value = "订单中产品实际单价", converter = ExcelDictConvert.class)
    private BigDecimal unitPrice;

    /**
     * 产品名称
     */
    @ExcelProperty(value = "产品名称")
    private String productName;

    /**
     * 产品图片url
     */
    @ExcelProperty(value = "产品图片url")
    private String productImg;

    /**
     * 产品规格
     */
    @ExcelProperty(value = "产品规格")
    private String productSpecs;

    /**
     * 产品单位
     */
    @ExcelProperty(value = "产品单位")
    private String productUnit;


}
